package service;

import java.util.List;

import dao.ArticleDao;
import domain.Article;
import domain.ArticleComment;
import domain.ArticleType;

public interface ArticleManager {
	int ARTICLE_PAGE_SIZE=3;
	
	public String getMsg();
	public ArticleDao getArticleDao();
	public boolean addArticleType(ArticleType at);
	public boolean deleteArticleType(int id);
	public boolean updateArticleType(ArticleType at);
	public ArticleType getArticleType(int id);
	
	public boolean addArticle(Article article, int articleType_Id);
	public boolean deleteArticle(int id);
	public boolean updateArticle(Article article);
	public Article getArticle(int id);
	
	public boolean addArticleComment(ArticleComment ac, int article_Id);
	public boolean deleteArticleComment(int id);
	public boolean updateArticleComment(ArticleComment ac);
	
	public List<Article> getAllArticleByTypeByPage(int articleType_Id,int pageNo);
	
	public int getArticleCountByType(int articleType_Id);
	public int getPageCountByType(int count,int pageSize);
	
	public List<Article> getAllArticleByPage(int pageNo);
	public int getArticleCount();
	public int getPageCount(int count,int pageSize);
	
	public List<ArticleType> getAllArticleType();
}
